package com.xiaoxu.scala_base.code._1_Scala集合

// Tuple 元组：(.......)
object TupleApp extends App {

  //元组最多能放几个？
  val a = (1, 2, 3, 4, 5,6,7)
  //遍历元组
  for (i <- 0 until (a.productArity)) {
    println(a.productElement(i))
  }

  val hostPort = ("localhost", 8080)
  hostPort._1
  hostPort._2

}
